package com.zhijiaoyun.controller.api;

import com.zhijiaoyun.controller.base.BaseController;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.Map;

/**
 * @author shisfish
 * @date 2017/6/6
 */
@Controller
@RequestMapping(value = "/api/setting", produces = "application/json; charset=utf-8")
public class SettingApi extends BaseController {

    /**
     * list by params
     *
     * @param title
     * @param bannerType
     * @return
     */
    @ResponseBody
    @RequestMapping(value = "/bannerList", method = RequestMethod.GET)
    public Map<String, Object> bannerList(String title, Integer bannerType) {
        return bannerService.listByParams(title, bannerType);
    }

}
